Api.GetVariable method
Gets the details of a user-defined variable.
Namespace: IntervalZero.KINGSTAR.OpcUa.Api
Assembly: IntervalZero.KINGSTAR.OpcUa.Api (in IntervalZero.KINGSTAR.OpcUa.Client.dll) Version: 4.4.0.0
Syntax
public KsReturn<UserVariable> GetVariable(
string Name,
UserVariable Parent = null
)
Public Function GetVariable(
Name As String,
Parent = null As UserVariable
) As KsReturn(Of UserVariable)
Parameters
Name
Type: string
The name of a variable.
Parent
Type: UserVariable
Default value: null
The parent folder of UserVariable. By default, it gets the variable from the root folder.
Return value
Type: KsReturn<UserVariable>
Returns a KsError code and a user-defined variable.
Remarks
- The Name string uses UTF-16 encoding.
- The variable can be used in KINGSTAR Scope and a real-time log.
Usable EtherCAT states
ecatOffline, ecatInit, ecatBoot, ecatPreOP, ecatSafeOP, ecatOP
Examples
N/A
See also